<?php
/**
 * index.phtml
 * Element of BigAaWSystem.
 * Date: 20/03/13
 * Time: 13:00
 * Developed by Marek Kaszewski
 */
if (!empty($statusMessage)) {
$link = $this->url('resendactivationemail', array('code' => $code))
?>
<div class="flash flash-failure" id="jstest">
    <img src="/images/icons/delete.png" alt="" width="16" height="16" />
			<span><?php echo sprintf($this->translate($statusMessage), '<a href=\'' . $link . '\'>','</a>'); ?></span>
    <div class="right"></div>
</div>
<?php
}
?>

<!-- Two Column (Equal) -->
<div class="two-column-equal"  style="width: 631px">
    <div class="column-right">

        <!-- Colour Tabbed Block (Full Width) -->
        <div class="block block-colour">

            <!-- Block Header -->
            <div class="head">
                <div class="cap-left"></div>
                <div class="cap-right"></div>
                <div class="content">

                    <!-- Block Title -->
                    <h2><?php echo $this->translate('Authenticate with local account') ?></h2>
                    <!-- /Block Title -->

                    <!-- Block Icon (Don't include this with tabs) -->
                    <a href="" title="" class="block-icon"><img src="images/block-icons/help.png" alt="" title="" width="32" height="32" /></a>
                    <!-- /Block Icon (Don't include this with tabs) -->

                </div>
                <div class="clear-both"></div>
            </div>
            <!-- /Block Header -->

            <!-- Block Content -->
            <div class="block-content">

                <!-- Tab One -->
                <div id="tab-four-one">

                    <!-- Standard Form (Small) -->
                    <form action="<?php echo $this->url('authenticate', array('action'=>'index'));?>" method="post" class="standard-form standard-form-small">
                        <fieldset>
                            <legend><?php echo $this->translate('Log in to the system') ?></legend>

                            <!-- Field -->
                            <div class="field <?php if(array_key_exists('email', $formMessages) && empty($message)) {echo 'field-error';} ?>">
                                <label for="field_1"><?php echo $this->translate('Email address') ?></label>
                                <input type="text" name="email" id="field_1" class="textbox" value="<?php if(empty($message)) {echo $this->escapeHTML($formData['email']);} ?>"/>
                                <p class="field-help">
                                    <?php if(array_key_exists('email', $formMessages)) {
                                        foreach ($formMessages['email'] as $key => $val) {
                                            echo $key . " ";
                                        }
                                    } else { echo $this->translate('Your email address you used during registration');}
                                    ?>
                                </p>
                            </div>
                            <!-- /Field -->

                            <!-- Field -->
                            <div class="field <?php if(array_key_exists('password', $formMessages) && empty($message)) {echo 'field-error';} ?>">
                                <label for="field_2"><?php echo $this->translate('Password') ?></label>
                                <input type="password" name="password" id="field_2" class="textbox" style="width: 250px" />
                                <p class="field-help"><?php if(array_key_exists('password', $formMessages)) {
                                        foreach ($formMessages['password'] as $key => $val) {
                                            echo $key . " ";
                                        }
                                    } else { echo '&nbsp;';}
                                    ?>
                                </p>
                            </div>
                            <!-- /Field -->
                            <div class="field">
                                <p class="field-help"><a href="<?php echo $this->url('passwordreminder') ?>" title="<?php echo $this->translate('I forgot my password'); ?>"><?php echo $this->translate('I forgot my password'); ?></a></p>
                            </div>

                        </fieldset>
                        <!-- Form Controls -->
                        <div class="form-controls">
                            <button type="submit" class="form-button-colour"><?php echo $this->translate('Login'); ?></button>
                        </div>
                        <!-- /Form Controls -->

                    </form>
                    <!-- /Standard Form (Small) -->

                </div>
                <!-- /Tab One -->

                <!-- Tab Two -->
                <!--div id="tab-four-two">

                Two

                </div-->
                <!-- /Tab Two -->

            </div>
            <!-- /Block Content -->

            <!-- Block Footer Cap -->
            <div class="block-footer-cap">
                <div class="cap-left"></div>
                <div class="cap-right"></div>
                <div class="content"></div>
            </div>
            <!-- /Block Footer Cap -->

        </div>
        <!-- /Colour Tabbed Block (Full Width) -->

    </div>
    <div class="clear-both"></div>
</div>
<!-- /Two Column (Equal) -->